-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve docs for TableProvider::supports_filters_pushdown
and remove deprecated function
#9923
Conversation
@@ -1430,12 +1430,12 @@ impl TableProvider for DataFrameTableProvider { | |||
Some(&self.plan) | |||
} | |||
|
|||
fn supports_filter_pushdown( | |||
fn supports_filters_pushdown( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Switches to using the non deprecated but very similarly named API
/// to optimise data retrieval. | ||
/// Note: the returned vector much have the same size as the filters argument. | ||
#[allow(deprecated)] | ||
/// Specify if DataFusion should provide filter expressions to the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried to improve the docs about what this was doing
@@ -154,28 +158,31 @@ pub trait TableProvider: Sync + Send { | |||
limit: Option<usize>, | |||
) -> Result<Arc<dyn ExecutionPlan>>; | |||
|
|||
/// Tests whether the table provider can make use of a filter expression | |||
/// to optimise data retrieval. | |||
#[deprecated(since = "20.0.0", note = "use supports_filters_pushdown instead")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This has been deprecated for quite a while
I was similarly confused when I first ran across this before figuring it out. Thanks for fixing. |
Co-authored-by: Phillip LeBlanc <phillip@leblanc.tech>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the review @phillipleblanc
cc @avantgardnerio as I think you maybe added the original API way back
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Thanks again @avantgardnerio and @phillipleblanc |
…ters_pushdown Deprecated function removed in apache/datafusion#9923
* chore: upgrade datafusion Deps Ref #690 * update concat and concat_ws to use datafusion_functions Moved in apache/datafusion#10089 * feat: upgrade functions.rs Upstream is continuing it's migration to UDFs. Ref apache/datafusion#10098 Ref apache/datafusion#10372 * fix ScalarUDF import * feat: remove deprecated suppors_filter_pushdown and impl supports_filters_pushdown Deprecated function removed in apache/datafusion#9923 * use `unnest_columns_with_options` instead of deprecated `unnest_column_with_option` * remove ScalarFunction wrappers These relied on upstream BuiltinScalarFunction, which are now removed. Ref apache/datafusion#10098 * update dataframe `test_describe` `null_count` was fixed upstream. Ref apache/datafusion#10260 * remove PyDFField and related methods DFField was removed upstream. Ref: apache/datafusion#9595 * bump `datafusion-python` package version to 38.0.0 * re-implement `PyExpr::column_name` The previous implementation relied on `DFField` which was removed upstream. Ref: apache/datafusion#9595
Which issue does this PR close?
Closes #9922
part of #7013
Rationale for this change
While debugging something with @pauldix yesterday, we were somewhat confused with the old API (as the default impl calls the deprecated function) and the docs weren't clear
We figured it out, but it was a paper cut that caused more confusion that it should have
What changes are included in this PR?
TableProvider::supports_filters_pushdown
TableProviderFilterPushDown
TableProvider::supports_filter_pushdown
Are these changes tested?
Yes by CI
Are there any user-facing changes?
Docs, and the deprecated API is now removed